import request from '@/utils/request'

export function list(query) {
    return request({
        url: '/energy/record/list',
        method: 'get',
        params: query
    })
}

export function listAll(query) {
    return request({
        url: '/energy/record/listAll',
        method: 'get',
        params: query
    })
}


export function get(id) {
    return request({
        url: '/energy/record/' + id,
        method: 'get'
    })
}

export function add(data) {
    return request({
        url: '/energy/record/add',
        method: 'post',
        data: data
    })
}

export function update(data) {
    return request({
        url: '/energy/record',
        method: 'put',
        data: data
    })
}

export function del(id) {
    return request({
        url: '/energy/record/' + id,
        method: 'delete'
    })
}

